class Solution(object):
    def mergeTwoLists(self, l1, l2):
        """
        :type l1: ListNode
        :type l2: ListNode
        :rtype: ListNode
        """
        dummyHead = ListNode()
        cur_node = dummyHead
        while l1 is not None and l2 is not None:
            if l1.val <= l2.val:
                cur_node.next = l1
                l1 = l1.next
            else:
                cur_node.next = l2
                l2 = l2.next
			cur_node = cur_node.next
        if l1 is not None:
            cur_node.next = l1
        if l2 is not None:
            cur_node.next = l2
        return dummyHead.next
